<?php
spl_autoload_register();

class Page{
    function index($id){
        $user = \vendor\Factory::getUser($id);

        $user->name = 'hai'.time();
var_dump($user);
        $this->test($id);

    }

    function test($id){
        $user =  \vendor\Factory::getUser($id);
var_dump($user);
        $user->age = date('s');
        $user->create_time = date('Y-m-d H:i:s');
        $user->edit();
    }
}
$page = new Page();
$page->index(1);